package com.cysyz.mylib.io.dirgenerator.impl;

import com.cysyz.mylib.io.dirgenerator.IDirGenerator;

import java.text.SimpleDateFormat;
import java.util.Date;

/**
 * 时间戳格式目录生成
 * 例如E:/NetBeans/Apache Tomcat 7.0.27/webapps/elec/WEB-INF/upload/2013/10/20
 * @author cy
 *
 */
public class DateStyleDirGenerator implements IDirGenerator {

	public String generate(String prefix, String postfix) {
		SimpleDateFormat simpleDateFormat = new SimpleDateFormat("/yyyy/MM/dd");
		return simpleDateFormat.format(new Date());
	}

}
